%%
clc;clear

%% define
syms k z Ts
Ts = 1e-4;
k = 10;
% z = tf('z')
sys_z = 0;
fc = (0.443/Ts)/k
for i=0:1:k-1
sys_z = sys_z + 1/k*z^-i;
end
[sys_z_num, sys_z_den] = numden(sys_z);
sys_z_num_coeff = sym2poly(sys_z_num);
sys_z_den_coeff = sym2poly(sys_z_den);

dbode(sys_z_num_coeff, sys_z_den_coeff, Ts);